import requests,base64,time,hashlib

def sign():
    r = "/api/movie"
    t = str(int(time.time()))
    s = ','.join([r, t])
    token = base64.b64encode(','.join([hashlib.sha1(s.encode()).hexdigest(), t]).encode()).decode()
    return token

def get_data(index,token):
    url = 'https://spa2.scrape.center/api/movie/?limit=10&offset=' + f'{index}' + '&token=' + f'{token}'
    resp = requests.get(url)
    data = resp.json()['results']

if __name__ == '__main__':
    token = sign()
    for index in range(0,91,10):
        get_data(index,token)